package com.boot.pojo;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * @TableName compensaterecords
 */
@Data
@TableName(value ="compensaterecords")
public class CompensateRecords {
    @TableId(type = IdType.AUTO)
    private Long id;

    @TableField("user_id")
    private Long userId;

    @TableField("business_type")
    private String businessType;

    private BigDecimal amount;

    @TableLogic
    //0待补偿，1已补偿
    private Integer status;

    @TableField("create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;


    @Override
    public String toString() {
        return "CompensateRecords{" +
                "userId=" + userId +
                ", businessType='" + businessType + '\'' +
                ", amount=" + amount +
                ", status=" + status +
                ", createTime=" + createTime +
                '}';
    }
}